﻿using System;
using System.Collections.Generic;
using System.Text;

namespace eKanBan.Model
{
    [Serializable]
    class MemberTask
    {
        public MemberTask()
        {
            Task = null;
            StartTime = DateTime.Now;
            FinishTime = DateTime.MinValue;
        }

        public MemberTask(Task task) : this()
        {            
            Task = task;
        }

        public Task Task { get; set; }
        public DateTime StartTime { get; set; }
        public DateTime FinishTime { get; set; }

        public bool Finished { get { return FinishTime != DateTime.MinValue; } }
        public override string ToString()
        {
            string str = Task.ToString();
            str += String.Format("\nStartTime: {0}\tFinishTime: {1}", StartTime, FinishTime);
            return str;
        }
    }
}
